#ifndef _CALC_PROC_H_
#define _CALC_PROC_H_

/* how many calc level do we have in max */
#define CALC_PROC_OPERATION_PRIORITY_LOWEST    (-1)
#define CALC_PROC_OPERATION_PRIORITY_LEVEL_MAX (2)

#define CALC_TEXT_EXP_ITEM_MAX (64)
#define CALC_PROC_IsNum(x) (('0' <= (x)) &&\
                            ('9' >= (x))) 

#define CALC_PROC_IsOp(x) (('+' == (x)) ||\
                           ('-' == (x)) ||\
                           ('*' == (x)) ||\
                           ('/' == (x)))

#define CALC_PROC_IsOpenBkt(x) ('(' == (x))

#define CALC_PROC_IsCloseBkt(x) (')' == (x))

#define CALC_PROC_IsBlank(x) (' ' == (x))

int CALC_Proc_CalcTextExp(IN char *pcInfixExpression,
                          OUT CALC_ITEM_S *pstResult);

#endif
